/*
 * BSM6.0
 *
 * Copyright 2012-2013 (C) SINODATA CO., LTD. All Rights Reserved.
 */
package com.zozo.guanli.vo;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

import org.codehaus.jackson.map.annotate.JsonSerialize;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * <p>
 * Description: 
 * </p>
 *
 * @author wangyazhou
 * @version 1.0

 * <p>
 * History: 
 *
 * Date                     Author         Version     Description
 * ---------------------------------------------------------------------------------
 * 2014-2-12 下午2:47:05          wangyazhou        1.0         To create
 * </p>
 *
 * @since 
 * @see     
 */
@Entity
@Table(name = "accessory")
public class Accessory implements java.io.Serializable {

    private Long id;
    private String name;// 名称
    private String code;//编码
    private String type;// 类型
    private String vendor;// 厂商
    private Date leavedate;// 出厂日期
    private Date mtdate;// 检修日期
    private int status; //配件状态
    private String fitcar; //适用车型
    private String mthistory; //检修历史
    private String miles; //公里数
    private Date opdate;// 出厂日期
    private String opperson; //操作人
    private Date ondate;
    private String cartype;
    private String position;
    private String xiuc;
    private Date downDate;
    private String mtresult;
    private String reason;

    public Accessory() {

    }

    @Id
    @Column(name = "ID", nullable = false, unique = true, updatable = false)
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    @Column(name = "NAME", nullable = true)
    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    @Column(name = "CODE", nullable = true)
    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    @Column(name = "TYPE", nullable = true)
    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    @Column(name = "VENDOR", nullable = true)
    public String getVendor() {
        return vendor;
    }

    public void setVendor(String vendor) {
        this.vendor = vendor;
    }

    @Column(name = "LEAVEDATE", length = 7)
    public Date getLeavedate() {
        return leavedate;
    }

    public void setLeavedate(Date leavedate) {
        this.leavedate = leavedate;
    }

    @Column(name = "MTDATA", length = 7)
    public Date getMtdate() {
        return mtdate;
    }

    public void setMtdate(Date mtdate) {
        this.mtdate = mtdate;
    }

    @Column(name = "STATUS")
    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    @Column(name = "FITCAR")
    public String getFitcar() {
        return fitcar;
    }

    public void setFitcar(String fitcar) {
        this.fitcar = fitcar;
    }

    @Column(name = "MTHISTORY")
    public String getMthistory() {
        return mthistory;
    }

    public void setMthistory(String mthistory) {
        this.mthistory = mthistory;
    }

    @Column(name = "MILES")
    public String getMiles() {
        return miles;
    }

    public void setMiles(String miles) {
        this.miles = miles;
    }

    @Column(name = "OPDATE", length = 7)
    public Date getOpdate() {
        return opdate;
    }

    public void setOpdate(Date opdate) {
        this.opdate = opdate;
    }

    @Column(name = "OPPERSON")
    public String getOpperson() {
        return opperson;
    }

    public void setOpperson(String opperson) {
        this.opperson = opperson;
    }

    @Column(name = "ONDATE", length = 7)
    public Date getOndate() {
        return ondate;
    }

    public void setOndate(Date ondate) {
        this.ondate = ondate;
    }

    @Column(name = "CARTYPE")
    public String getCartype() {
        return cartype;
    }

    public void setCartype(String cartype) {
        this.cartype = cartype;
    }

    @Column(name = "POSITION")
    public String getPosition() {
        return position;
    }

    public void setPosition(String position) {
        this.position = position;
    }

    @Column(name = "XIUC")
    public String getXiuc() {
        return xiuc;
    }

    public void setXiuc(String xiuc) {
        this.xiuc = xiuc;
    }

    @Column(name = "DOWNDATE", length = 7)
    public Date getDownDate() {
        return downDate;
    }

    public void setDownDate(Date downDate) {
        this.downDate = downDate;
    }

    @Column(name = "MTRESULT")
    public String getMtresult() {
        return mtresult;
    }

    public void setMtresult(String mtresult) {
        this.mtresult = mtresult;
    }

    @Column(name = "REASON")
    public String getReason() {
        return reason;
    }

    public void setReason(String reason) {
        this.reason = reason;
    }

    @Override
    public String toString() {
        return "Accessory [id=" + id + ", name=" + name + ", type=" + type + ", vendor=" + vendor + ", leavedate=" + leavedate + ", mtdate=" + mtdate + ", status=" + status + ", fitcar=" + fitcar + ", mthistory=" + mthistory + ", miles=" + miles + ", opdate=" + opdate + ", opperson=" + opperson + ", ondate=" + ondate + ", cartype=" + cartype + ", position=" + position + ", xiuc=" + xiuc + ", downDate=" + downDate + ", mtresult=" + mtresult + ", reason=" + reason + "]";
    }

}
